﻿using System;
using System.Collections.Generic;
using System.Collections;
using System.Linq;
using System.Text;

namespace CinemaProject
{

    public class Ticket
    {
        
        private int id;
        private Schedule schedule;
        private Seat seat;
        private decimal price;
        private ArrayList tickets;
        private User user;
        
        public Ticket()
        {
            id = 0;
            schedule = null;
            seat = null;
            price = 0;
            tickets = null;
            user = null;
        }
        public Ticket(int id, Schedule schedule, Seat seat, decimal price, ArrayList tickets, User user)
        {
            this.id = id;
            this.schedule = schedule;
            this.seat = seat;
            this.price = price;
            tickets = new ArrayList();
            user = new User();
        }

        #region Get&Set
        public int _id
        {
            get { return id; }
            set { id = value; }
        }
        public Schedule _schedule
        {
            get { return schedule; }
            set { schedule = value; }
        }
        public Seat _seat
        {
            get { return seat; }
            set { seat = value; }
        }
        public decimal _price
        {
            get { return price; }
            set { price = value; }
        }
        //public User _user
        //{
        //    get {return user; }
        //    set {user = new User;}
        //}
        #endregion
        public void AddTickets(Ticket ticket)
        {
            tickets.Add(ticket);
        }
       
    }
}
